package com.tovast.demo.domain;

import lombok.*;
import org.springframework.data.jpa.domain.AbstractPersistable;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import java.io.Serializable;
import java.util.Date;

/**
 * 考勤记录
 * Created by zjp on 2016/9/30.
 */
@Entity
@Getter
@Setter
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class Attendance  implements Serializable {

    private static final long serialVersionUID = -1435418594498031301L;
    @Id
    @GeneratedValue
    private Integer id;
    /**
     * 员工
     */
    @ManyToOne
    private User user;
    /**
     * 出勤时间
     */
    private Date inTime;
    /**
     * 退勤时间
     */
    private Date outTime;
    /**
     * 备注
     */
    private String description;
}
